package org.hp.service.dictionary;

import com.github.pagehelper.PageHelper;
import org.hp.bean.Case;
import org.hp.dao.dictionary.CaseDao;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;
import java.util.Map;

@Service
public class CaseServiceImpl implements CaseService {
    @Resource
    CaseDao caseDao;

    @Override
    public List<Case> queryGene(Integer limit, Integer page, String cname) {
        PageHelper.startPage(page,limit);
        return caseDao.queryGene(cname);
    }

    @Override
    public List<Case> queryGeneResult(Integer limit, Integer page, String cname) {
        PageHelper.startPage(page,limit);
        return caseDao.queryGeneResult(cname);
    }

    @Override
    public List<Case> queryCheck(Integer limit, Integer page, String cname) {
        PageHelper.startPage(page,limit);
        return caseDao.queryCheck(cname);
    }

    @Override
    public List<Map> queryDelGene() {
        return caseDao.queryDelGene();
    }

    @Override
    public List<Map> queryDelGeneResult() {
        return caseDao.queryDelGeneResult();
    }

    @Override
    public List<Map> queryDelCheck() {
        return caseDao.queryDelCheck();
    }

    @Override
    public int addGene(Case c) {
        return caseDao.addGene(c);
    }

    @Override
    public int addGeneResult(Case c) {
        return caseDao.addGeneResult(c);
    }

    @Override
    public int addCheck(Case c) {
        return caseDao.addCheck(c);
    }

    @Override
    public int delGene(Integer cid) {
        return caseDao.delGene(cid);
    }

    @Override
    public int delGeneResult(Integer cid) {
        return caseDao.delGeneResult(cid);
    }

    @Override
    public int delCheck(Integer cid) {
        return caseDao.delCheck(cid);
    }

    @Override
    public int returnGene(Integer cid) {
        return caseDao.returnGene(cid);
    }

    @Override
    public int returnGeneResult(Integer cid) {
        return caseDao.returnGeneResult(cid);
    }

    @Override
    public int returnCheck(Integer cid) {
        return caseDao.returnCheck(cid);
    }

    @Override
    public Case queryOneGene(Integer cid) {
        return caseDao.queryOneGene(cid);
    }

    @Override
    public Case queryOneGeneResult(Integer cid) {
        return caseDao.queryOneGeneResult(cid);
    }

    @Override
    public Case queryOneCheck(Integer cid) {
        return caseDao.queryOneCheck(cid);
    }

    @Override
    public int updateGene(Case c) {
        return caseDao.updateGene(c);
    }
}
